package com.teacher.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.teacher.pojo.dto.flow.MyApproveGetDto;
import com.teacher.pojo.entity.Flow;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.teacher.pojo.vo.flow.FlowApproveDetailsVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 流程总表 Mapper 接口
 * </p>
 *
 * @author zfm
 * @since 2021-08-03
 */
public interface FlowMapper extends BaseMapper<Flow> {

    /**
     * 获取审批详情
     *
     * @param flowId
     * @return
     */
    List<FlowApproveDetailsVo> getFlowApproveDetails(@Param("flowId") Long flowId);

    /**
     * 查询已办
     *
     * @param page
     * @param dto
     * @param teacherKey
     * @return
     */
    IPage<Flow> getPage(@Param("page") Page<Flow> page, @Param("dto") MyApproveGetDto dto, @Param("teacherKey") String teacherKey);

}
